#ifndef BULL_HAL_OTA_FLASH_H
#define BULL_HAL_OTA_FLASH_H

#include <stdbool.h>
#include <stdint.h>

#include "bull_hal_adapter.h"
#include "bull_hal_types.h"
#include "esp_ota_ops.h"
#include "esp_log.h"



OPERATE_RET bull_hal_ota_write_data(uint32_t update_handle,uint8_t *data,uint16_t len);
OPERATE_RET bull_hal_ota_write_end(uint32_t update_handle,const esp_partition_t * update_partition);
bool bull_hal_ota_start_check(void);
const void* bull_hal_ota_get_update_pariton(void);
OPERATE_RET bull_hal_ota_begin(void* update_partition,OUT uint32_t *update_handle);
OPERATE_RET bull_hal_ota_ease_last_boot(void);



#endif
